"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const Global_1 = require("../../models/Global");
// This is a demo code file
// Feel free to delete it
async function default_1(call) {
    // Error
    const ret = await Global_1.Global.db.collection('pandian').find({}).toArray();
    if (!ret) {
        call.error('记录不存在');
        return;
    }
    call.succ({
        data: ret.map(item => ({
            _id: item._id.toString(),
            SerialNum: item.SerialNum,
            time: item.time,
            Location: item.Location
        }))
    });
}
exports.default = default_1;
